package cn.com.dcsgo.library.admin.service;

import cn.com.dcsgo.library.admin.domain.dto.PageDTO;
import cn.com.dcsgo.library.admin.domain.po.BorrowRecord;
import cn.com.dcsgo.library.admin.domain.query.BorrowRecordPageQuery;
import cn.com.dcsgo.library.admin.domain.request.BorrowBookRequest;
import cn.com.dcsgo.library.admin.domain.request.ReturnBookRequest;
import cn.com.dcsgo.library.admin.domain.vo.BorrowRecordVO;
import com.baomidou.mybatisplus.extension.service.IService;

/**
 * @author Dcsgo
 * @since 2024-09-02
 */
public interface IBorrowRecordsService extends IService<BorrowRecord> {
    PageDTO<BorrowRecordVO> queryBorrowRecordsByPage(BorrowRecordPageQuery pageQuery);

    Long borrowBook(BorrowBookRequest request);

    boolean isBorrowed(Long copyId);

    void returnBook(ReturnBookRequest request);
}
